/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package entity;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Embeddable;

/**
 *
 * @author Human Booster
 */
@Embeddable
public class LicencesoftwarePK implements Serializable {
    @Basic(optional = false)
    @Column(name = "id")
    private int id;
    @Basic(optional = false)
    @Column(name = "LifeTime_id")
    private int lifeTimeid;
    @Basic(optional = false)
    @Column(name = "Software_id")
    private int softwareid;
    @Basic(optional = false)
    @Column(name = "LicenceCounterLimit_id")
    private int licenceCounterLimitid;

    public LicencesoftwarePK() {
    }

    public LicencesoftwarePK(int id, int lifeTimeid, int softwareid, int licenceCounterLimitid) {
        this.id = id;
        this.lifeTimeid = lifeTimeid;
        this.softwareid = softwareid;
        this.licenceCounterLimitid = licenceCounterLimitid;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getLifeTimeid() {
        return lifeTimeid;
    }

    public void setLifeTimeid(int lifeTimeid) {
        this.lifeTimeid = lifeTimeid;
    }

    public int getSoftwareid() {
        return softwareid;
    }

    public void setSoftwareid(int softwareid) {
        this.softwareid = softwareid;
    }

    public int getLicenceCounterLimitid() {
        return licenceCounterLimitid;
    }

    public void setLicenceCounterLimitid(int licenceCounterLimitid) {
        this.licenceCounterLimitid = licenceCounterLimitid;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (int) id;
        hash += (int) lifeTimeid;
        hash += (int) softwareid;
        hash += (int) licenceCounterLimitid;
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof LicencesoftwarePK)) {
            return false;
        }
        LicencesoftwarePK other = (LicencesoftwarePK) object;
        if (this.id != other.id) {
            return false;
        }
        if (this.lifeTimeid != other.lifeTimeid) {
            return false;
        }
        if (this.softwareid != other.softwareid) {
            return false;
        }
        if (this.licenceCounterLimitid != other.licenceCounterLimitid) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "entity.LicencesoftwarePK[ id=" + id + ", lifeTimeid=" + lifeTimeid + ", softwareid=" + softwareid + ", licenceCounterLimitid=" + licenceCounterLimitid + " ]";
    }
    
}
